home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
SunSoft Catalyst CDWARE 1996 May to August
/
Catalyst CDWARE 1996 May to August.iso
/
.products
/
TIBCO
/
_install
/
install_unbundled
next >
Wrap
Text File
|
1996-02-29
|
2KB
|
113 lines
#!/bin/sh
#
# Installation shell script for Catalyst CDware
#
# Usage: install_unbundled -m<mountpoint> -p<productpath>
#
# Created: June 12, 1991
# Last Revised: May 23, 1994
#
# Use this installation script to install your product from Catalyst CDware
#
#
# For technical support, please call.
# +1 415 336.3742 (CDware SPARC) or +1 415 336.3941 (CDware x86)
#
# get command line parameters
#
# function for error exiting
end_it () {
echo " "
echo "Hit return to end ... "
read answer
exit 0
}
# set PRODUCT_SIZE to the size of your product in kbytes
PRODUCT_SIZE=4200
#
# get complete paths
#
#
# get location of installation directory
##
echo
echo
echo "The software must be installed by root and under subdirectory /opt"
echo "Enter your root password when prompted"
echo ""
echo ""
INSTALL_DIR=/opt
#
# verify free disk space
#
echo
echo "Verifying free disk space under /opt ..."
FREE_SPACE=0
df=/tmp/FREE.$$
#
# WARNING:
# --------
# For Solaris 2.4, the df line below will need to be updated because
# the standard output of the df command has changed in Solaris 2.4
#
/usr/bin/df -k $INSTALL_DIR | sed /kbytes/d | sed -e '3,$d' | sed -e '1,$s/ */ /g' > $df
case `/usr/bin/wc -l $df | sed -e 's/^ *//' | cut -f1 -d" " ` in
1) FREE_SPACE=`cat $df | cut -f4 -d" "` ;;
2) FREE_SPACE=`cat $df | sed 1d | sed 's/^ *//' | cut -f3 -d" "` ;;
esac
if [ -n $FREE_SPACE ]
then
if [ $FREE_SPACE -lt $PRODUCT_SIZE ]
then
echo
echo
echo "The product installation requires $PRODUCT_SIZE kbytes of"
echo "free disk space. There is only $FREE_SPACE kbytes of free"
echo "disk space in the selected filesystem. Please free up some"
echo "disk space and try this installation again."
echo
echo "Exiting the installation script."
end_it
fi
fi
/bin/rm $df 2>/dev/null
#
# Get user id
#
if [ -f /usr/ucb/whoami ]
then
USER=`/usr/ucb/whoami` ; export USER
else
echo " "
echo "Cannot find /usr/ucb/whoami"
echo " "
end_it
fi
#
# Check if root
#
if [ "$USER" = "root" ]; then
cd /opt
zcat $COMPANY_DIR/_install/ship_1.1.tar.Z | tar xvf -
cd ship_1.1;pkgadd -d .
else
echo ""
echo " You must be SU to install software. Please enter password."
echo ""
su root -c 'cd /opt;zcat $COMPANY_DIR/_install/ship_1.1.tar.Z | tar xvf -;cd ship_1.1;pkgadd -d .'
fi
end_it